import http from "../utils/http";

// 接口示例
const testApi = () => {
  return http({
    url: '/student/getstudent',
    method: 'get'
  })
}

//=====================================报表管理
// 业务报表
// 场内停车记录报表
// 进场通道下拉框OK
const getPass = (data) => {
  return http({
    url: '/report/service/pass',
    method: 'get',
    params: {
      ...data
    }
  })
}

//停车场下拉框OK
const getParking = () => {
  return http({
    url: '/report/service/parking',
    method: 'get'
  })
}

//条件查询场内停车记录报表
const searchConditional = (data) => {
  return http({
    url: '/report/service/conditional',
    method: 'get',
    params: {
      ...data
    }
  })
}

//场内停车记录列表
const getList = () => {
  return http({
    url: '/report/service/list',
    method: 'get'
  })
}

//添加黑白名单
const addBlackName = (data) => {
  return http({
    url: '/report/service/blackName',
    method: 'post',
    data: {
      ...data
    }
  })
}

// 统计报表
// 日收费报表
// 图表视图
// 本年交易额柱状图
const getTradeOfMoney = () => {
  return http({
    url: '/report/dailyChartView/tradeOfMoney',
    method: 'get',
  })
}

// 岗亭排行榜
const getLeaderboard = () => {
  return http({
    url: '/report/dailyChartView/leaderboard',
    method: 'get',
  })
}

// 列表视图
// 日收费报表列表
const getDailyList = (data) => {
  return http({
    url: '/report/statistics/daily/list',
    method: 'get',
    params: {
      ...data
    }
  })
}

// 停车场下拉框
const getStatisticsParking = () => {
  return http({
    url: '/report/statistics/parking',
    method: 'get',
  })
}

// 日收费报表条件查询
const searchDailyConditional = (data) => {
  return http({
    url: '/report/statistics/daily/conditional',
    method: 'post',
    data: {
      ...data
    }
  })
}

// ETC结算报表
//系统管理
//etc请求列表渲染
const getEtcList = (data) => {
  return http({
    url: '/report/ETCForm/list',
    method: 'get',
    params: { ...data }
  })
}

//etc条件查询--ljy
const getETCseach = (data) => {
  return http({
    url: '/report/ETCForm/conditional',
    method: 'get',
    params: { ...data }
  })
}

//etc日月年
const getYear = (data) => {
  return http({
    url: '/report/ETCForm/dayWeekYear',
    method: 'get',
    params: { ...data }
  })
}

// =================================================================================================

const LogShow = () => {
  return http({
    url: '/logInfo/getAllLogInfo',
    method: 'get',
  })
}

//数据查询表格接口
const geteDataquery = () => {
  return http({
    url: '/SuperAdmin/AllDataList',
    method: 'get'
  })
}

//数据查询进出场车道下拉框接口
const passDataquery = () => {
  return http({
    url: '/pass',
    method: 'get'
  })
}
//数据查询停车场下拉框接口
const parkingDataquery = () => {
  return http({
    url: '/parking',
    method: 'get'
  })
}
//运维人员表格接口
const geteOperationmaintenance = () => {
  return http({
    url: '/operations/OprationMemberManage/selectAllMember',
    method: 'get'
  })
}
//添加运维人员接口
const geteaddMember = () => {
  return http({
    url: '/operations/OprationMemberManage/addMember',
    method: 'post'
  })
}
//条件查询运维人员接口
const getselectMemberByConditions = () => {
  return http({
    url: '/operations/OprationMemberManage/selectMemberByConditions',
    method: 'post'
  })
}
//条件查询运维人员下拉框接口
const getuserList = () => {
  return http({
    url: '/operations/OprationMemberManage/userList',
    method: 'get'
  })
}

//=======================================

export { getuserList,getselectMemberByConditions,geteaddMember,geteOperationmaintenance,parkingDataquery,passDataquery,testApi, getPass, getParking, searchConditional, getList, addBlackName, getDailyList, getStatisticsParking, searchDailyConditional, getTradeOfMoney, getLeaderboard, getEtcList, getETCseach, getYear,LogShow, geteDataquery, }
